package com.system.permissiondemo.beans;

import lombok.Data;

import javax.validation.constraints.Min;

/**
* @Description:    分页类
* @Author:         Joe
* @CreateDate:     2020/3/26 20:33
*/
@Data
public class PageQuery {
    @Min(value = 1)
    private Integer pageNo = 1;
    @Min(value = 1)
    private Integer pageSize = 10;

    private Integer offset;

    public Integer getOffset(){
        return (pageNo - 1) *10;
    }
}
